<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
欢迎您：<span th:text="${user.name}">请登录</span><br>
<span th:text="'欢迎您:' + ${user.name} + '!(字符拼接)'"></span><br>

<span th:text="|欢迎您:${user.name}竖杠拼接|"></span><br>
<span th:text="${user.age}"></span><br>
<span th:text="${user.age}%2 == 0"></span><br>
<span th:text="${user.sex} ? '男':'女'"></span><br>
<span th:if="${user.age} < 24">小鲜肉</span><br>
<div th:switch="${user.role}">
    <p th:case="'admin'">用户是管理员</p>
    <p th:case="'manager'">用户是经理</p>
    <p th:case="*">用户是别的玩意</p>
</div>

<script th:inline="javascript">
    const user = /*[[${user}]]*/ {};
    const age = /*[[${user.age}]]*/ 20;
    console.log(user);
    console.log(age)
</script>
</body>
</html>